from api import config, ssh, sshFlash
import toml

from logger import logger

'''
    读取配置文件CONFIG
    日志初始化LOGGER
    启动TCP服务SERVER.START
    线程1与网关交互SELF.GW.HANDLE  线程2读取excel模板UNTILS.RUN_WITH_THREAD(C.START)
                                连接串口开始测试SELF.AT.START
                                测试所有用例SELF.CASE_LIST_PROGRESS(KEY,CASE_LIST)
'''


def main():
    config.Config.arg = toml.load('config.toml')
    logger.Config.arg = config.Config.arg
    logger.add_handle()
    server = ssh.Connect()
    server.start()


if __name__ == '__main__':
    main()
